<%@page language="java" contentType="text/html; charset=UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ taglib prefix="web" uri="http://meerkat.qunar.com/web"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<web:designCss/>
<%@include file="/WEB-INF/include/head.jsp" %>
</head>
<body>
    <div class="wrapper">
        <web:titleBar title="添加报名序号" />

        <div class="main content">
            <table>
                <tr>
                    <td><textarea id="codelist" cols="70" rows="20"></textarea></td>
                </tr>
                <tr>
                    <td>可使用<br/>
                    <code>
                    报名序号1,身份证号1<br/>
                    报名序号2,身份证号2<br/>
                    报名序号n,身份证号n<br/>
                    </code>
                    增加多条记录</td>
                </tr>
                <tr>
                    <td>
                        <a href="list.htm" class="button button-green">返回</a>
                        <a href="#" id="submit" class="button button-red">提交</a>
                    </td>
                </tr>
            </table>
        </div>
    </div>
    <script type="text/javascript">
        $(document).ready(function(){
            $('#submit').click(function() {
                var codelist=$('#codelist').val();

                $.post('add.htm', {
                    "codelist" : codelist
                }, function(resp) {
                    if (resp.status==0) {
                        alert(resp.data);
                        window.location.href='list.htm';
                    } else {
                        alert(resp.message);
                    }
                });
            });
        });
    </script>
</body>
</html>
